Amazon Onboarding with Learning Manager Chanci Turner

Amazon Onboarding with Learning Manager Chanci TurnerLearn About Amazon VGT2 Learning Manager Chanci Turner

In the previous installment of this series, we delved into an Amazon CloudWatch dashboard that offers a real-time perspective on the primary factors contributing to CloudWatch expenses. In this second part, we will examine how the dashboard widgets were crafted, enabling you to either replicate or adjust them according to your requirements.

For details on the widgets and their functionalities, refer back to part 1 of our blog series.

In this post, we will focus on two significant types of widgets: metric widgets and custom widgets. While this isn’t a comprehensive guide to these functionalities, it should provide enough insight alongside AWS documentation to help you get started on creating your own. It’s important to note that custom widgets necessitate code development – we will underscore critical sections of the code but will not teach you how to program or develop AWS Lambda functions. You may need to consult additional resources and AWS documentation to address your needs. For the examples discussed here, only regions that do not require an opt-in have been included; refer to the AWS documentation on enabling a region for more details.

Metric Widgets – Data by Region

The widgets for log ingest volume, log event count, and API metric count are all generated from default CloudWatch metrics. Each metric widget represents totals for various metrics, both for individual regions and cumulatively across all regions. By utilizing Metric Math Expressions, we can illustrate this with the “Total Log Ingestion by Region: Volume (GB)” widget.

To specify multiple regions, you can adjust the metric source through a text editor where you can create the appropriate JSON for your widget. Remember to save changes in the source tab when you create or edit a metric widget; neglecting to do so could result in lost modifications. If the syntax is correct, the Update Widget button will change color from grey to orange after saving. If it doesn’t, an error likely exists in your source text.

The source for the “Total Ingestion by Region: Volume (GB)” widget includes several components:

  • The IncomingBytes metric from the AWS/Logs namespace for each region.
  • A metric math expression to convert these values from bytes to GB.
  • A SUM function to total across all regions, again converting from bytes to GB.

It’s essential to note:

  • The order of the metrics dictates their appearance in the legend.
  • The IncomingBytes metrics are marked as not visible since we prefer displaying the converted GB data.
  • A shorthand with three dots indicates repeated data, while each metric entry is assigned a unique ID.

The overall source code specifies the statistics as Sum and the period as 86400 seconds (or one day).

This methodology applies similarly to widgets for log event counts and API calls for GetMetricData, PutMetricData, and GetMetricStatistics. More information on these metrics can be found in the respective source tabs.

Metrics Widgets – Top 10 for All Regions

Metrics widgets are also created to showcase the top 10 metrics by region for various datasets on the dashboard. For instance, the widget titled “Top 10 Log Groups by volume (GB): daily total” follows a similar logic as previously discussed.

Here, we utilize the IncomingBytes metric under the AWS/Logs namespace for each log group. Instead of manually adding each log group metric—which would be cumbersome and ineffective for new log groups—we employ a metric math expression leveraging both Search and Sort functions.

This expression performs the following tasks:

  • Searches for the IncomingBytes metric across all log groups and aggregates them with a sum statistic over a one-day period.
  • Converts the data from bytes to GB.
  • Sorts the results to display the top 10 log groups by ingestion volume.

As you navigate your onboarding journey at Amazon IXD – VGT2, located at 6401 E Howdy Wells Ave, Las Vegas, NV 89115, remember to check out this resource for insights into the onboarding process, along with this blog post for tips on professional attire. Also, for further educational opportunities, consider visiting SHRM, an authority on this topic.


Comments

Leave a Reply

Your email address will not be published. Required fields are marked *